import Vue from "vue";
import VueRouter from "vue-router";

import Home from "../views/Home.vue";

import UserLogin from "../views/user/Login.vue";
import CustomerFillingIndex from "../views/customerFiling/index.vue"
import AddCustomer from "../views/customerFiling/AddCustomer.vue"
import UpdateCustomer from "../views/customerFiling/UpdateCustomer.vue";

import limitApplication from "../views/Jointguarantee/index.vue"
import AddMember from "../views/Jointguarantee/addMember.vue"
import MemberInfo from "../views/Jointguarantee/MemberInfo.vue"
import BasicInfo from "../views/Jointguarantee/BasicInfo.vue"


Vue.use(VueRouter);

const routes = [
	{ path: "/login", component: UserLogin },
	{
		path: "/",
		component: Home,
		children: [

			{ path: "/customerFiling", component: CustomerFillingIndex },
			{ path: "/addCustomer", component: AddCustomer },
			{ path: "/updateCustomer", component: UpdateCustomer },

			{ path: "/limitApplication", component: limitApplication },
			{ path: "/addMember", component: AddMember,children:[
					  {
						path: "/basic-info",
						component: BasicInfo
					  },
					  {
						path: "/member-info",
						component: MemberInfo
					  }					
			] },
		]

	}

];

const router = new VueRouter({
	routes
});

export default router;
